package com.yxx.community.controller;

import com.yxx.community.dto.FileDTO;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author: YuXinXin
 * @Description: 上传文件
 * @Date:Created in 21:36 2020/2/14
 **/
@RestController
public class FileController {

  @PostMapping("/file/upload")
  public FileDTO upload(){
    FileDTO fileDTO = new FileDTO();
    fileDTO.setSuccess(1);
    fileDTO.setMessage("上传成功");
    fileDTO.setUrl("/images/me.jpg");
    return fileDTO;
  }
}
